package com.zenni.utils;
import org.apache.log4j.Logger;
import org.apache.log4j.PropertyConfigurator;
import org.apache.log4j.xml.DOMConfigurator;

/**
 * Created by douglasj on 3/7/16.
 */
public class LogUtils {
    // Initialize Log4j logs
    //private static Logger LogUtils = Logger.getLogger(LogUtils.class.getName());

    // This is to print log for the beginning of the test case, as we usually run so many test cases as a test suite

    public static void startTestCase(String sTestCaseName){
        LogUtils.info("****************************************************************************************");

        LogUtils.info("****************************************************************************************");

        LogUtils.info("$$$$$$$$$$$$$$$$$$$$$                 "+sTestCaseName+ "       $$$$$$$$$$$$$$$$$$$$$$$$$");

        LogUtils.info("****************************************************************************************");

        LogUtils.info("****************************************************************************************");

    }

    //This is to print log for the ending of the test case

    public static void endTestCase(String sTestCaseName){

        LogUtils.info("XXXXXXXXXXXXXXXXXXXXXXX             "+"-E---N---D-"+"             XXXXXXXXXXXXXXXXXXXXXX");

        LogUtils.info("X");

        LogUtils.info("X");

        LogUtils.info("X");

        LogUtils.info("X");

    }

    // Need to create these methods, so that they can be called

    public static void info(String message) {

        LogUtils.info(message);

    }

    public static void warn(String message) {

        LogUtils.warn(message);

    }

    public static void error(String message) {

        LogUtils.error(message);

    }

    public static void fatal(String message) {

        LogUtils.fatal(message);

    }

    public static void debug(String message) {

        LogUtils.debug(message);

    }

}
